home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1994 #2
/
Monster Media No. 2 (Monster Media)(1994).ISO
/
pcboard
/
prfl200.zip
/
CONVERT.PPE
(
.txt
)
< prev
next >
Wrap
PCBoard Programming Language Executable
|
1994-06-16
|
8KB
|
360 lines
;------------------------------------------------------------------------------
; .ss.
; `²²'
; .,sS$Ss,,s$ .,sS$$$Ss. .,sS$Ss,,s$ .ss. .sSs.
; .d$$²^°²$$$$'.d$P²°^^²$P'.d$$²^°²$$$$'.$$$' .$$$²Sb,.
; $$$' .$$$' $$$²Sçsµ²' .$$$' .$$$'.$$$' .$$$' `$$b.
; $$$b,,d$$$' ,$$$b,....,s$$$$b,,d$$$'.$$$;.,$$$' ;$$$
; `²S$$S²²S$$S²°²S$$$$S²°°²S$$$$$$',$$S²°²S$S'.sS$$$P²'
; .sS²°$$$²²°"' d²°'
; .$$² .$$'
; $$$.,d$$'
; `²S$$S²'
;------------------------------------------------------------------------------
; P.P.L.X. 2.OO (C)1996 - Lone Runner / AEGiS CoRP'96
;------------------------------------------------------------------------------
; PPE 2.OO (plain) - Analysis ON - Postprocessing ON
;------------------------------------------------------------------------------
Integer INTEGER001
Integer INTEGER002
Integer INTEGER003
String STRING001
String STRING002
String STRING003
String STRING004
String STRING005
String STRING006
String STRING007
String STRING008
String STRING009
String STRING010
String STRING011
String STRING012
String STRING013
String STRING014
String STRING015
String STRING016
String STRING017
String STRING018
String STRING019
String STRING020
String STRING021
String STRING022
String STRING023
String STRING024
String STRING025
String STRING026
String STRING027
BigStr BIGSTR001
;------------------------------------------------------------------------------
STRING024 = ""
INTEGER002 = ""
If (Exist(PPEPath() + "PROFILE.CFG")) Then
FOpen 1, PPEPath() + "PROFILE.CFG", 0, 0
FGet 1, STRING024
FGet 1, STRING025
FGet 1, STRING026
FClose 1
If (Ferr(1)) Then
PrintLn "Error opening Configuration File. Inform SysOp Immediately!"
Endif
Else
PrintLn "Configuration file does not exist. This program will not run without"
PrintLn "the 'PROFILE.CFG' file in the same directory as the 'PROFILE.PPE'."
End
Endif
For INTEGER003 = 1 To 50
STRING027 = Mid(STRING024, INTEGER003, 1)
INTEGER001 = Asc(STRING027)
INTEGER002 = INTEGER002 + INTEGER001
Next
If ((INTEGER002 * Len(Strip(STRING024, " "))) * 9 == STRING025) Then
Goto LABEL001
Else
Goto LABEL008
Endif
:LABEL001
Newline
PrintLn "@X0DP@X0Arofile @X0DC@X0Aonversion @X0DPPE @X0E1@X0A.@X0E0 @X0C(@X0Ec@X0C) @X0DTSCN@X0Aet @X0DS@X0Aoftware @X0DD@X0Aesigns @X0D1994@X0A."
Newline
PrintLn "@X0BExample@X0A: @X0EY:\PCB\PPE @X0B<-- NO TRAILING BACKSLASH"
InputStr "Path to Version 1.X Index files", STRING022, 15, 25, Mask_Ascii(), 128 + 64
If (STRING022 == "") Then
End
Endif
Newline
PrintLn "@X0DP@X0Alease @X0DH@X0Aold@X0D...."
Print "@X0DC@X0Aonverting @X0BIndex--@X0C" + STRING023
If (Exist(STRING022 + "\INDEX-A")) Then
STRING023 = "A"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-B")) Then
STRING023 = "B"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-C")) Then
STRING023 = "C"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-D")) Then
STRING023 = "D"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-E")) Then
STRING023 = "E"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-F")) Then
STRING023 = "F"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-G")) Then
STRING023 = "G"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-H")) Then
STRING023 = "H"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-I")) Then
STRING023 = "I"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-J")) Then
STRING023 = "J"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-K")) Then
STRING023 = "K"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-L")) Then
STRING023 = "L"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-M")) Then
STRING023 = "M"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-N")) Then
STRING023 = "N"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-O")) Then
STRING023 = "O"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-P")) Then
STRING023 = "P"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-Q")) Then
STRING023 = "Q"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-R")) Then
STRING023 = "R"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-S")) Then
STRING023 = "S"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-T")) Then
STRING023 = "T"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-U")) Then
STRING023 = "U"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-V")) Then
STRING023 = "V"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-W")) Then
STRING023 = "W"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-X")) Then
STRING023 = "X"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-Y")) Then
STRING023 = "Y"
Gosub LABEL002
Endif
If (Exist(STRING022 + "\INDEX-Z")) Then
STRING023 = "Z"
Gosub LABEL002
Endif
:LABEL002
Backup 1
Print "@X0C" + STRING023
FOpen 1, STRING022 + "\Index-" + STRING023, 0, 3
FOpen 2, STRING026 + "\Index-" + STRING023 + ".NEW", 1, 0
:LABEL003
FGet 1, STRING001
If (Left(STRING001, 16) == "Version 2.0 Data") Then
Goto LABEL006
End
ElseIf (Left(STRING001, 10) == "Dummy Name") Then
FGet 1, STRING002
FGet 1, STRING003
BIGSTR001 = "Version 2.0 Data"
Goto LABEL004
End
ElseIf (STRING001 == "") Then
If (STRING002 == "") Then
Newline
PrintLn "The conversion ended on this Index as if it had come to the end of the file"
PrintLn "but there is still data continuing. Check the Index file for a blank line where"
PrintLn "there shouldn't be one. And start the conversion over."
Newline
FClose 1
FClose 2
Delete STRING026 + "\Index-" + STRING023 + ".NEW"
End
Endif
If ((STRING023 == "Z") || (STRING023 == "")) Then
FClose 1
FClose 2
Copy STRING022 + "\Index-Z", STRING026 + "\Index-Z.OLD"
Delete STRING022 + "\Index-Z"
Copy STRING026 + "\Index-Z.NEW", STRING026 + "\Index-Z"
Delete STRING026 + "\Index-Z.NEW"
Goto LABEL007
End
Else
FClose 1
FClose 2
Copy STRING022 + "\Index-" + STRING023, STRING026 + "\Index-" + STRING023 + ".OLD"
Delete STRING022 + "\Index-" + STRING023
Copy STRING026 + "\Index-" + STRING023 + ".NEW", STRING026 + "\Index-" + STRING023
Delete STRING026 + "\Index-" + STRING023 + ".NEW"
STRING023 = ""
Return
Endif
Else
If (Left(STRING001, 1) == ";") Then
Newline
PrintLn "@X0DE@X0Arror in @X0DI@X0Andex-@X0C" + STRING023 + " @X0DD@X0Aata file. @X0DR@X0Aepairing and @X0DP@X0Aroceeding."
Print "@X0DC@X0Aonverting @X0BIndex-@X0C" + STRING023
Goto LABEL003
Else
FGet 1, STRING002
FGet 1, STRING003
Gosub LABEL005
:LABEL004
FPutLn 2, BIGSTR001
Goto LABEL003
Endif
Endif
:LABEL005
STRING021 = Left(STRING001, 25)
STRING004 = Right(Left(STRING001, 27), 1)
STRING005 = Right(Left(STRING001, 30), 2)
STRING006 = Right(Left(STRING001, 56), 25)
STRING007 = Right(Left(STRING001, 82), 25)
STRING008 = Right(Left(STRING001, 95), 12)
STRING009 = Right(Left(STRING001, 151), 55)
STRING010 = Right(Left(STRING001, 164), 12)
STRING011 = Right(Left(STRING001, 191), 26)
STRING012 = Right(Left(STRING001, 217), 25)
STRING013 = Right(Left(STRING001, 243), 25)
STRING014 = Right(Left(STRING002, 21), 20)
STRING015 = Right(Left(STRING002, 47), 20)
STRING016 = Right(Left(STRING002, 79), 30)
STRING017 = Right(Left(STRING002, 106), 25)
STRING018 = Right(Left(STRING002, 173), 65)
STRING019 = Right(Left(STRING002, 245), 70)
STRING020 = Right(STRING003, 132)
BIGSTR001 = STRING021 + ";" + STRING004 + ";" + Left(STRING005, 3) + ";" + Left(STRING006, 25) + ";" + Left(STRING007, 25) + ";" + Left(STRING008, 12) + ";" + Left(STRING009, 54) + ";" + Left(STRING010, 12) + ";" + Left(STRING011, 26) + ";" + Left(STRING012, 25) + ";" + Left(STRING013, 25) + ";" + Left(STRING014, 35) + ";" + Left(STRING015, 20) + ";" + Left(STRING016, 35) + ";" + Left(STRING017, 35) + ";" + Left(STRING018, 55) + ";" + Left(STRING019, 55) + ";" + Left("", 35) + ";" + Left("", 50) + ";" + Left("", 8) + ";" + Left(STRING020, 65) + ";" + Left("", 50) + ";"
Return
:LABEL006
Newline
PrintLn "@X0AThis data has already been converted to 2.0 Data."
End
:LABEL007
Copy STRING022 + "\List.dat", STRING026 + "\List.dat"
Delete STRING022 + "List.dat"
Newlines 2
PrintLn "@X0AYour data has been converted and your old data has been stored with"
PrintLn "@X0Aa '.OLD' extention."
End
:LABEL008
Newline
PrintLn "You do not currently have a REGISTERED version. This Data cannot be"
PrintLn "converted until you REGISTER this PPE or you may restart your Data"
PrintLn "by deleteing the Index files."
End
;------------------------------------------------------------------------------
;
; Usage report (before postprocessing)
;
; ■ Statements used :
;
; 9 End
; 52 Goto
; 54 Let
; 3 Print
; 16 PrintLn
; 37 If
; 3 FOpen
; 7 FClose
; 8 FGet
; 1 FPutLn
; 6 Delete
; 1 InputStr
; 27 Gosub
; 2 Return
; 8 Newline
; 1 Newlines
; 1 Backup
; 5 Copy
;
;
; ■ Functions used :
;
; 2 *
; 111 +
; 9 ==
; 1 <
; 1 <=
; 2 >=
; 37 !
; 2 &&
; 2 ||
; 1 Len(
; 1 Mid()
; 40 Left()
; 17 Right()
; 1 Ferr()
; 1 Asc()
; 1 Strip()
; 1 Mask_Ascii()
; 2 PPEPath()
; 27 Exist()
;
;------------------------------------------------------------------------------
;
; Analysis flags : No flag
;
;------------------------------------------------------------------------------
;
; Postprocessing report
;
; 1 For/Next
; 0 While/EndWhile
; 36 If/Then or If/Then/Else
; 0 Select Case
;
;------------------------------------------------------------------------------
; AEGiS Corp - Break the routines, code against the machines!
;------------------------------------------------------------------------------